<?PHP

	class tpl_tools {
		
		public static function tools(){
		
			$news_html = '';
			if(empty($GLOBALS['OUTPUT']->news)){
				$news_html = "<i>{$GLOBALS['LANG']->lang_admin->nonews}</i>";
			}else{
				foreach($GLOBALS['OUTPUT']->news as $data){
					$date = date($GLOBALS['OUTPUT']->settings['long_date_format'],$data['time']);;
					
					$news_html .= <<<EOV
<div style='border-bottom: 1px solid #797B7F;'>
	<b>{$data['subject']}</b> &nbsp;&nbsp;-&nbsp;&nbsp; <i>{$date}</i><br />
</div>
<div style='font-size: 10px; margin-left: 10px; margin-top: 5px; margin-bottom: 20px;'>{$data['body']}</div>
EOV;
				}
			}
			
			return	tpl_globals::header() .
				<<<EOV
<div class='table_header'>&nbsp;{$GLOBALS['LANG']->lang_admin->livenews}</div>
<table style='width: 100%;' cellspacing='1' cellpadding='5'>
	<tr valign='top'>
		<td class='td2' width='70%'>{$news_html}</td>
		<td class='td2' width='30%'><div align='center'><a href='./index.php?act=admin{$GLOBALS['OUTPUT']->ses}&page=updatemanager'><img src='http://www.x7chat.com/updates/updates.php?x=vimg&v={$GLOBALS['OUTPUT']->version[0]}' border='0' /></a></div><br />
			<table border='0' align='center' cellspacing='1' cellpadding='5'>
				<tr>
					<td class='td1'>{$GLOBALS['LANG']->lang_admin->curver}: </td><td class='td1'> {$GLOBALS['OUTPUT']->version[1]}</td>
				</tr>
				<tr>
					<td class='td1'>{$GLOBALS['LANG']->lang_admin->latestver}: </td><td class='td1'> {$GLOBALS['OUTPUT']->lastestver}</td>
				</tr>
			</table>
		</td>
	</tr>
</table>
EOV
.
			tpl_globals::footer();
				
		}
		
	}

?>